<div>
    <div class="row">
        <div class="col-md-1 padding-r-0">
            <div class=" border-radius ">
                <div class="margin-xs-r  treeview ">
                    <ul class="list-group text-center border-radius">
                        <li class="list-group-item node-orgTree "
                            v-for="(item,index) in callingContactManageInfo.accessControls" :key="index"
                            @click="swatchAccessControl(item)"
                            :class="{'vc-node-selected':callingContactManageInfo.conditions.machineId == item.machineId}">
                            {{item.machineName	}}
                        </li>
                    </ul>
                </div>
            </div>
        </div>
        <div class="col-md-11">
            <div class="ibox ">
                <div class="ibox-title">
                    <h5>
                        <vc:i18n name="查询条件"></vc:i18n>
                    </h5>
                    <div class="ibox-tools" style="top:10px;">

                    </div>
                </div>

                <div class="ibox-content">
                    <div class="row">
                        <div class="col-sm-4">
                            <div class="form-group">
                                <input type="text" :placeholder="vc.i18n('请选择设备名称','callingContactManage')"
                                       v-model="callingContactManageInfo.conditions.deviceName" class=" form-control">
                            </div>
                        </div>
                        <div class="col-sm-4">
                            <div class="form-group">
                                <input type="text" :placeholder="vc.i18n('请选择呼叫号码','callingContactManage')"
                                       v-model="callingContactManageInfo.conditions.callingNum" class=" form-control">
                            </div>
                        </div>
                        <div class="col-sm-2">
                            <button type="button" class="btn btn-primary btn-sm" v-on:click="_queryCallingContactMethod()">
                                <vc:i18n name="查询" namespace="callingContactManage"></vc:i18n>
                            </button>
                            <!--                            <button type="button" class="btn btn-primary btn-sm" v-on:click="_resetVisitMethod()">-->
                            <!--                                <vc:i18n name="重置" namespace="callingContactManage"></vc:i18n>-->
                            <!--                            </button>-->
                        </div>
                    </div>
                </div>
            </div>

            <div class="ibox">
                <div class="ibox-title">
                    <h5>
                        <vc:i18n name="通讯录信息" namespace="chargeMachineManage"></vc:i18n>
                    </h5>
                    <div class="ibox-tools" style="top:10px;">
                        <button type="button" class="btn btn-primary btn-sm" v-on:click="_openChooseCallingContactModal()">
                            <vc:i18n name="添加" namespace="callingContactManage"></vc:i18n>
                        </button>
                    </div>
                </div>
                <div class="ibox-content">
                    <table class="footable table table-stripped toggle-arrow-tiny" data-page-size="15">
                        <thead>
                        <tr>
                            <th class="text-center"><span><vc:i18n name='通讯录ID'
                                                                   namespace='callingContactManage'></vc:i18n></span>
                            </th>
                            <th class="text-center"><span><vc:i18n name='设备名称'
                                                                   namespace='callingContactManage'></vc:i18n></span>
                            </th>
                            <th class="text-center"><span><vc:i18n name='呼叫号码'
                                                                   namespace='callingDeviceManage'></vc:i18n></span>
                            </th>
                            <th class="text-center"><span><vc:i18n name='云呼平台'
                                                                   namespace='callingDeviceManage'></vc:i18n></span>
                            </th>
                            <th class="text-center"><span><vc:i18n name='操作'></vc:i18n></span></th>
                        </tr>
                        </thead>
                        <tbody>
                        <tr v-for="callingContact in callingContactManageInfo.callingContacts">
                            <td class="text-center">{{callingContact.deviceId}}</td>
                            <td class="text-center">{{callingContact.deviceName}}</td>
                            <td class="text-center">{{callingContact.callingNum}}</td>
                            <td class="text-center">{{callingContact.platformName}}</td>
                            <td class="text-center">
                                <div class="btn-group">
                                    <button class="btn-white btn btn-xs"
                                            v-on:click="_openDeleteCallingContactModel(callingContact)"><span><vc:i18n
                                            name='删除'></vc:i18n></span></button>
                                </div>
                            </td>
                        </tr>
                        </tbody>
                    </table>
                    <!-- 分页 -->
                    <vc:create path="frame/pagination"></vc:create>
                </div>
            </div>
        </div>
    </div>

    <vc:create path="accessControl/editCallingContact"></vc:create>
    <vc:create path="accessControl/deleteCallingContact"></vc:create>
    <vc:create path="accessControl/chooseCallingDevice" emitChooseCallingDevice="callingContactManage" emitLoadData="callingContactManage"></vc:create>
</div>